
<%@ page import="com.surelution.projects.crm.MemberCard" %>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="layout" content="main" />
        <g:set var="entityName" value="${message(code: 'memberCard.label', default: 'MemberCard')}" />
        <title><g:message code="default.list.label" args="[entityName]" /></title>
    </head>
    <body>
        <div class="nav">
            <span class="menuButton"><a class="home" href="${createLink(uri: '/')}"><g:message code="default.home.label"/></a></span>
        </div>
        <div class="body">
            <h1><g:message code="default.list.label" args="[entityName]" /></h1>
            <g:if test="${flash.message}">
            <div class="message">${flash.message}</div>
            </g:if>
            <div class="list">
                <table>
                    <thead>
                        <tr>
                        
                            <g:sortableColumn property="id" title="${message(code: 'memberCard.id.label', default: 'Id')}" />
                        
                            <g:sortableColumn property="market" title="${message(code: 'memberCard.market.label', default: 'market')}" />

                            <g:sortableColumn property="cardNo" title="${message(code: 'memberCard.cardNo.label', default: 'Card No')}" />

                            <g:sortableColumn property="holderName" title="${message(code: 'memberCard.holderName.label', default: 'Holder Name')}" />
                        
                            <g:sortableColumn property="accountAcceptBranch" title="${message(code: 'memberCard.accountAcceptBranch.label', default: 'Account Accept Branch')}" />
                        
                            <g:sortableColumn property="accountAcceptDate" title="${message(code: 'memberCard.accountAcceptDate.label', default: 'Account Accept Date')}" />
                        
                            <g:sortableColumn property="connectTime" title="${message(code: 'memberCard.connectTime.label', default: 'Connect Time')}" />
                        
                        </tr>
                    </thead>
                    <tbody>
                    <g:each in="${memberCardInstanceList}" status="i" var="memberCardInstance">
                        <tr class="${(i % 2) == 0 ? 'odd' : 'even'}">
                        
                            <td><g:link action="show" id="${memberCardInstance.id}">${memberCardInstance.id}</g:link></td>
                        
                            <td>${fieldValue(bean: memberCardInstance, field: "market.name")}</td>

                            <td>${fieldValue(bean: memberCardInstance, field: "cardNo")}</td>
                        
                            <td>${fieldValue(bean: memberCardInstance, field: "holderName")}</td>
                        
                            <td>${fieldValue(bean: memberCardInstance, field: "accountAcceptBranch")}</td>
                        
                            <td><g:formatDate date="${memberCardInstance.accountAcceptDate}" /></td>
                        
                            <td><g:formatDate date="${memberCardInstance.connectTime}" /></td>
                        
                        </tr>
                    </g:each>
                    </tbody>
                </table>
            </div>
            <div class="paginateButtons">
                <g:paginate total="${memberCardInstanceTotal}" />
            </div>
        </div>
    </body>
</html>
